--- import Default from '../../../layouts/Default.astro'; import Thread from '../../../components/Thread.svelte' import Comment from '../../../components/Comment.svelte' import type Thread from '../../../models/Thread'; import { api } from '../../../lib/api'; import { processThreadIn } from '../../../lib/thread'; const { board } = Astro.params; const data = await api('get', `thread/${board}/${Astro.params.tid}`); if(data.status === 404) return Astro.redirect('/404'); const thread: Thread = await data.json(); await processThreadIn(board, thread, true); const comments: Comment[] = thread.comments; --- {comments.map((comment) => ( ))}